home *** CD-ROM | disk | FTP | other *** search
/ Scene Storm / Scene Storm - Volume 1.iso / coding / tools / gcc / gcc270_src.lha / gcc-2.7.0-amiga / config / rs6000 / powerpc.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-06-15  |  2.8 KB  |  87 lines

  1. /* Definitions of target machine for GNU compiler,
  2.    for IBM RS/6000 PowerPC running AIX version 3.2.
  3.    Copyright (C) 1993, 1994, 1995 Free Software Foundation, Inc.
  4.    Contributed by David Edelsohn (edelsohn@npac.syr.edu).
  5.  
  6. This file is part of GNU CC.
  7.  
  8. GNU CC is free software; you can redistribute it and/or modify
  9. it under the terms of the GNU General Public License as published by
  10. the Free Software Foundation; either version 2, or (at your option)
  11. any later version.
  12.  
  13. GNU CC is distributed in the hope that it will be useful,
  14. but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  16. GNU General Public License for more details.
  17.  
  18. You should have received a copy of the GNU General Public License
  19. along with GNU CC; see the file COPYING.  If not, write to
  20. the Free Software Foundation, 59 Temple Place - Suite 330,
  21. Boston, MA 02111-1307, USA.  */
  22.  
  23.  
  24. #include "rs6000/rs6000.h"
  25.  
  26. #undef ASM_SPEC
  27. #define ASM_SPEC "-u -mppc"
  28.  
  29. #undef CPP_PREDEFINES
  30. #define CPP_PREDEFINES "-D_IBMR2 -D_POWER -D_AIX -D_AIX32 \
  31. -Asystem(unix) -Asystem(aix) -Acpu(powerpc) -Amachine(powerpc)"
  32.  
  33. #undef CPP_SPEC
  34. #define CPP_SPEC "\
  35. %{posix: -D_POSIX_SOURCE} \
  36. %{!mcpu*: \
  37.   %{mpower: %{!mpower2: -D_ARCH_PWR}} \
  38.   %{mpower2: -D_ARCH_PWR2} \
  39.   %{mpowerpc*: -D_ARCH_PPC} \
  40.   %{mno-powerpc: %{!mpower: %{!mpower2: -D_ARCH_COM}}} \
  41.   %{!mno-powerpc: -D_ARCH_PPC}} \
  42. %{mcpu=common: -D_ARCH_COM} \
  43. %{mcpu=power: -D_ARCH_PWR} \
  44. %{mcpu=powerpc: -D_ARCH_PPC} \
  45. %{mcpu=rios: -D_ARCH_PWR} \
  46. %{mcpu=rios1: -D_ARCH_PWR} \
  47. %{mcpu=rios2: -D_ARCH_PWR2} \
  48. %{mcpu=rsc: -D_ARCH_PWR} \
  49. %{mcpu=rsc1: -D_ARCH_PWR} \
  50. %{mcpu=403: -D_ARCH_PPC} \
  51. %{mcpu=mpc403: -D_ARCH_PPC} \
  52. %{mcpu=ppc403: -D_ARCH_PPC} \
  53. %{mcpu=601: -D_ARCH_PPC -D_ARCH_PWR} \
  54. %{mcpu=mpc601: -D_ARCH_PPC -D_ARCH_PWR} \
  55. %{mcpu=ppc601: -D_ARCH_PPC -D_ARCH_PWR} \
  56. %{mcpu=603: -D_ARCH_PPC} \
  57. %{mcpu=mpc603: -D_ARCH_PPC} \
  58. %{mcpu=ppc603: -D_ARCH_PPC} \
  59. %{mcpu=604: -D_ARCH_PPC} \
  60. %{mcpu=mpc604: -D_ARCH_PPC} \
  61. %{mcpu=ppc604: -D_ARCH_PPC}"
  62.  
  63. #undef TARGET_DEFAULT
  64. #define TARGET_DEFAULT (MASK_POWERPC | MASK_NEW_MNEMONICS)
  65.  
  66. #undef PROCESSOR_DEFAULT
  67. #define PROCESSOR_DEFAULT PROCESSOR_PPC601
  68.  
  69. /* These are not necessary when we pass -u to the assembler, and undefining
  70.    them saves a great deal of space in object files.  */
  71.  
  72. #undef ASM_OUTPUT_EXTERNAL
  73. #undef ASM_OUTPUT_EXTERNAL_LIBCALL
  74. #define ASM_OUTPUT_EXTERNAL(FILE, DECL, NAME)    \
  75. { rtx _symref = XEXP (DECL_RTL (DECL), 0);    \
  76.   if ((TREE_CODE (DECL) == VAR_DECL        \
  77.        || TREE_CODE (DECL) == FUNCTION_DECL)    \
  78.       && (NAME)[0] != '*'            \
  79.       && (NAME)[strlen (NAME) - 1] != ']')    \
  80.     {                        \
  81.       char *_name = (char *) permalloc (strlen (XSTR (_symref, 0)) + 5); \
  82.       strcpy (_name, XSTR (_symref, 0));    \
  83.       strcat (_name, TREE_CODE (DECL) == FUNCTION_DECL ? "[DS]" : "[RW]"); \
  84.       XSTR (_symref, 0) = _name;        \
  85.     }                        \
  86. }
  87.